<?php

/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/
/*
Route::get('/', 'WelcomeController@home');

Route::get('home', 'HomeController@home');

Route::controllers([
	'auth' => 'Auth\AuthController',
	'password' => 'Auth\PasswordController',
]);
*/


Route::get('/', 'Index\HomeController@index');

Route::get('/item', 'Index\ItemController@items');
Route::get('/item/{id}', 'Index\ItemController@item')->where('id', '\d+');

Route::controllers([
    'about' => 'Index\AboutController',
    'account' => 'Index\AccountController',
    'password' => 'Index\PasswordController',
    'user' => 'Index\UserController',
]);




Route::group(['prefix' => 'admin', 'namespace' => 'Admin', 'middleware' => 'admin'], function () {
    Route::get('/', 'HomeController@index');
    Route::controllers([
        'item' => 'ItemController',
        'catalog' => 'CatalogController',
        'area' => 'AreaController',
        'match' => 'MatchController',
        'user' => 'UserController',
        'role' => 'RoleController',
    ]);
});





Route::group(['prefix' => 'api', 'namespace' => 'Api'], function () {
    Route::controllers([
        'catalog' => 'CatalogController',
        'area' => 'AreaController'
    ]);
});
